{%load static%}
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <script  src="{% static 'js/axios.min.js' %}"></script>
    <title>测试axios</title>
</head>
<body>
    <h1>测试axios</h1>

    <div id="my-data"></div>
    <script>
        axios.get("/info/nodes_count",{
            params:{
                label:'中药材'
            }
        })
            .then(function(response) {
                var message = Object.keys(response.data)
                console.log(message)
                document.getElementById("my-data").innerHTML = message;
            })
            .catch(function(error) {
                console.log(error);
            });
    </script>

</body>
</html>